import { IUser } from '../types/Request';
import { IRespinseUser } from '../types/Response';
import server from '../utils/request';

// 获取用户信息  Promise<返回的数据的数据类型>
export async function login (data: IUser): Promise<IRespinseUser> {
  return await server.request({
    url: '/api/users/login',
    method: 'post',
    data
  });
}
